import random

randnum=random.randint(1,100)
while True:
    usernum = int(input("请输入一个数字"))
    if(usernum<randnum):
        print("猜小了")
    elif usernum>randnum:
        print("猜大了")
    elif usernum==randnum:
        print("猜对了")
        break



